package com.terren.spider.db.service.impl;

import java.util.List;

import org.springframework.stereotype.Service;

import com.terren.spider.db.basic.BasicServiceSupportImpl;
import com.terren.spider.db.service.SpiderWebTestTaskService;
import com.terren.spider.entity.core.SpiderWebTestTask;
@Service("spiderWebTestTaskService")
public class SpiderWebTestTaskServiceImpl extends BasicServiceSupportImpl implements SpiderWebTestTaskService{
	private final String SQL_MAPPER = "spiderWebTestTaskMapper.";

	@Override
	public List<SpiderWebTestTask> getSpiderTaskList() throws Exception {
		return basicDao.findForList(SQL_MAPPER+"getSpiderTaskList", null);
	}

	@Override
	public void updateStatus(SpiderWebTestTask spiderTask) throws Exception {
		basicDao.save(SQL_MAPPER+"updateStatus", spiderTask);
		
	}

	@Override
	public SpiderWebTestTask getOneSpiderTask() throws Exception {
		// TODO Auto-generated method stub
		return basicDao.findForObject(SQL_MAPPER+"getOneSpiderTask", null);
	}

}
